package com.bdqn.crm.pojo;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @TableName cst_activity
 */
@TableName(value = "cst_activity")
@Data
public class CstActivity implements Serializable {
    /**
     * 编号
     */
    @TableId
    private Long atvId;

    /**
     * 客户编号
     */
    private String atvCustNo;

    /**
     * 客户姓名
     */
    private String atvCustName;

    /**
     * 时间
     */
    private Date atvDate;

    /**
     * 地点
     */
    private String atvPlace;

    /**
     * 概要
     */
    private String atvTitle;

    /**
     * 详细信息
     */
    private String atvDesc;

    /**
     * 备注
     */
    private String atvRemark;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        CstActivity other = (CstActivity) that;
        return (this.getAtvId() == null ? other.getAtvId() == null : this.getAtvId().equals(other.getAtvId()))
                && (this.getAtvCustNo() == null ? other.getAtvCustNo() == null : this.getAtvCustNo().equals(other.getAtvCustNo()))
                && (this.getAtvCustName() == null ? other.getAtvCustName() == null : this.getAtvCustName().equals(other.getAtvCustName()))
                && (this.getAtvDate() == null ? other.getAtvDate() == null : this.getAtvDate().equals(other.getAtvDate()))
                && (this.getAtvPlace() == null ? other.getAtvPlace() == null : this.getAtvPlace().equals(other.getAtvPlace()))
                && (this.getAtvTitle() == null ? other.getAtvTitle() == null : this.getAtvTitle().equals(other.getAtvTitle()))
                && (this.getAtvDesc() == null ? other.getAtvDesc() == null : this.getAtvDesc().equals(other.getAtvDesc()))
                && (this.getAtvRemark() == null ? other.getAtvRemark() == null : this.getAtvRemark().equals(other.getAtvRemark()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getAtvId() == null) ? 0 : getAtvId().hashCode());
        result = prime * result + ((getAtvCustNo() == null) ? 0 : getAtvCustNo().hashCode());
        result = prime * result + ((getAtvCustName() == null) ? 0 : getAtvCustName().hashCode());
        result = prime * result + ((getAtvDate() == null) ? 0 : getAtvDate().hashCode());
        result = prime * result + ((getAtvPlace() == null) ? 0 : getAtvPlace().hashCode());
        result = prime * result + ((getAtvTitle() == null) ? 0 : getAtvTitle().hashCode());
        result = prime * result + ((getAtvDesc() == null) ? 0 : getAtvDesc().hashCode());
        result = prime * result + ((getAtvRemark() == null) ? 0 : getAtvRemark().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", atvId=").append(atvId);
        sb.append(", atvCustNo=").append(atvCustNo);
        sb.append(", atvCustName=").append(atvCustName);
        sb.append(", atvDate=").append(atvDate);
        sb.append(", atvPlace=").append(atvPlace);
        sb.append(", atvTitle=").append(atvTitle);
        sb.append(", atvDesc=").append(atvDesc);
        sb.append(", atvRemark=").append(atvRemark);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}